package com.zerox.service.impl;

import com.zerox.mapper.SupplierMapper;
import com.zerox.pojo.Supplier;
import com.zerox.service.SupplierService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SupplierServiceImpl implements SupplierService {
    @Autowired
    private SupplierMapper supplierMapper;
    
    @Override
    public List<Supplier> getList(String supName, Integer page, Integer limit) {
        return supplierMapper.getList(supName, page , limit);
    }
    
    @Override
    public Integer count(String supContact) {
        return supplierMapper.count(supContact);
    }
    
    
    @Override
    public int add(Supplier supplier) {
        return supplierMapper.add(supplier);
    }
    @Override
    public int delete(Integer id) {
        return supplierMapper.delete(id);
    }
    
    @Override
    public Integer update(Supplier supplier) {
        return supplierMapper.update(supplier);
    }
    
    @Override
    public Supplier selectById(Integer id) {
        return supplierMapper.selectById(id);
    }
}
